package com.hp.monitoring.pingmon;

import java.util.ArrayList;
import java.util.Collection;

import com.google.gwt.user.client.rpc.IsSerializable;

public class HostPoolImpl implements HostPool, IsSerializable {

	private String name;
	private ArrayList<Host> allHosts = new ArrayList<Host>();
	
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	public void addHost(Host host) {
		this.allHosts.add(host);	
	}

	public void removeHost(Host host) {
		this.allHosts.remove(host);		
	}
	
	public Collection<Host> getActiveHosts() {
		return allHosts;
	}

	public Collection<Host> getHosts() {
		return allHosts;
	}

	public void setHosts(Collection<Host> hosts) {
		allHosts.addAll(hosts);		
	}
	
}
